import {createRouter,createWebHistory} from 'vue-router';

const routes = [
    {
        path: '/',
        name: 'dashboard',
        component: () => import('@/views/Dashboard.vue'),
        children: [
            {
                path: '/',
                name: 'defaultPage',
                component: () => import('@/views/DefaultPage.vue')
            },
            {
                path: '/detection',
                name: 'detectionFrom',
                component: () => import('@/views/DetectionFrom.vue'),
            },
            {
                path: '/login',
                name: 'login',
                component: ()=> import('@/views/Login.vue')
            },
            {
                path: '/submitRecord',
                name: 'submitRecord',
                component: ()=> import('@/views/SubmitRecord.vue')
            }
        ]
    },
]

const router = createRouter({
    history: createWebHistory(),
    routes : routes
})

export default router
